import { createRouter, createWebHashHistory, RouteRecordRaw } from "vue-router";
import HomeView from "../views/HomeView.vue";

const routes: Array<RouteRecordRaw> = [
  {
    path: "/",
    name: "home",
    component: HomeView,
  },
  {
    path: "/community",
    name: "community",
    component: () => import("../views/CommunityView.vue"),
  },
  {
    path: "/persional",
    name: "persional",
    component: () => import("../views/PersionalView.vue"),
  },
  {
    path: "/train",
    name: "train",
    component: () => import("../views/TrainView.vue"),
  },
  {
    path: "/sport",
    name: "sport",
    component: () => import("../views/SportView.vue"),
  },
  {
    path: "/echartsview01",
    name: "echartsview01",
    component: () => import("../views/EchartsView01.vue"),
  },
  {
    path: "/echartsview02",
    name: "echartsview02",
    component: () => import("../views/EchartsView02.vue"),
  },
  {
    path: "/sport",
    name: "sport",
    component: () => import("../views/SportView.vue"),
  },
  {
    path: "/loading",
    name: "loading",
    component: () => import("../views/LoadingView.vue"),
  },
  {
    path: "/login",
    name: "login",
    component: () => import("../views/LonginView.vue"),
  },
  {
    path: "/register",
    name: "register",
    component: () => import("../views/RegisterView.vue"),
  },
];

const router = createRouter({
  history: createWebHashHistory(),
  routes,
});

export default router;
